import {
  PrimaryGeneratedColumn,
  CreateDateColumn,
  UpdateDateColumn,
  DeleteDateColumn,
  VersionColumn,
} from 'typeorm';

export abstract class BaseModel {
  @PrimaryGeneratedColumn({ comment: '主键' })
  id: number;
  @CreateDateColumn({ comment: '创建时间' })
  createdAt: Date;
  @UpdateDateColumn({ comment: '更新时间' })
  updatedAt: Date;
  @DeleteDateColumn({ comment: '删除时间' })
  deletedAt: Date;
  @VersionColumn()
  version: number;
}
